<template>
  <div class="attr-list">
    <CommonAttr />
    <px-form>
      <px-form-item label="URL">
        <px-input
          v-model="
            //@ts-ignores
            curComponent.propValue.url
          "
        />
      </px-form-item>
      <px-form-item label="Name">
        <px-input
          v-model="
            //@ts-ignores
            curComponent.propValue.name
          "
        />
      </px-form-item>
      <px-form-item label="是否可拖拽">
        <px-switch
          v-model="
            //@ts-ignores
            curComponent.propValue.isDrag
          "
          inline-prompt
          active-text="是"
          inactive-text="否"
        />
      </px-form-item>
    </px-form>
  </div>
</template>
<script setup lang="ts">
import CommonAttr from "@visual/custom-component/common/CommonAttr.vue";
import { useComponent } from "@visual/stores";
import { storeToRefs } from "pinia";

const componentStore = useComponent();
const { curComponent } = storeToRefs(componentStore);
</script>
